home *** CD-ROM | disk | FTP | other *** search
/ MacAddict 114 / macaddict114.cdr / Software / Utilities / macam.0.8.4.dmg / macam sources / utilities / MiscTools.h < prev    next >
Encoding:
C/C++ Source or Header  |  2002-05-22  |  1.8 KB  |  54 lines

  1. /*
  2.  macam - webcam app and QuickTime driver component
  3.  Copyright (C) 2002 Matthias Krauss (macam@matthias-krauss.de)
  4.  
  5.  This program is free software; you can redistribute it and/or modify
  6.  it under the terms of the GNU General Public License as published by
  7.  the Free Software Foundation; either version 2 of the License, or
  8.  (at your option) any later version.
  9.  
  10.  This program is distributed in the hope that it will be useful,
  11.  but WITHOUT ANY WARRANTY; without even the implied warranty of
  12.  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  13.  GNU General Public License for more details.
  14.  
  15.  You should have received a copy of the GNU General Public License
  16.  along with this program; if not, write to the Free Software
  17.  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  18.  $Id: MiscTools.h,v 1.1.1.1 2002/05/22 04:57:21 dirkx Exp $
  19.  */
  20.  
  21. #ifndef _MISC_TOOLS_
  22. #define _MISC_TOOLS_
  23.  
  24. #include <Carbon/Carbon.h>
  25. #include <IOKit/IOKitLib.h>
  26. #include <IOKit/IOCFPlugIn.h>
  27. #include <IOKit/usb/IOUSBLib.h>
  28. #include "GlobalDefs.h"
  29.  
  30. //String copy and conversion functions
  31. void CStr2PStr(const char* cstr, unsigned char* pstr);
  32. void PStr2CStr(const unsigned char* pstr, char* cstr);
  33. void PStr2PStr(const unsigned char* src, unsigned char* dst);
  34. void CStr2CStr(const char* src,char* dst);
  35.  
  36. //Memory dump - for debugging
  37. void DumpMem(unsigned char* buf, long len);
  38.  
  39. //Wrappers for thread stuff
  40. void ChangeMyThreadPriority(int delta);
  41. int GetMyThreadPriority(void);
  42. void OSXYieldToAnyThread(void);
  43.  
  44. //Pipes info
  45. short CountPipes(IOUSBInterfaceInterface **intf);
  46. void ShowPipeInfo(IOUSBInterfaceInterface **intf, short idx);
  47. void ShowPipesInfo(IOUSBInterfaceInterface **intf);
  48.  
  49. //Resoultion lookup
  50. short WidthOfResolution(CameraResolution r);
  51. short HeightOfResolution(CameraResolution r);
  52.  
  53.  
  54. #endif